import request from '@/utils/request'
import qs from 'qs'

export function login(data) {
  return request({
    url: '/user/user_login',
    method: 'post',
    data: qs.stringify(data)
  })
}

export function getMenu(user_id) {
  return request({
    url: '/user/get_menu',
    method: 'get',
    params: { user_id }
  })
}
export function getInfo(user_id, user_token) {
  return request({
    url: '/user/user_info',
    method: 'get',
    params: { user_id, user_token }
  })
}
export function logout() {
  return request({
    url: '/vue-admin-template/user/logout',
    method: 'post'
  })
}
